namespace KDS.Mes.Migrations
{
    using System;
    using System.Collections.Generic;
    using System.Data.Entity.Infrastructure.Annotations;
    using System.Data.Entity.Migrations;
    
    public partial class AddOnline : DbMigration
    {
        public override void Up()
        {
            //CreateTable(
            //    "dbo.T_Online",
            //    c => new
            //        {
            //            Id = c.Int(nullable: false, identity: true),
            //            LineId = c.Int(nullable: false),
            //            SeatID = c.String(maxLength: 50),
            //            OnlineTime = c.DateTime(nullable: false),
            //            OfflineTime = c.DateTime(nullable: false),
            //            WorkTime = c.String(maxLength: 20),
            //            OfflineFlag = c.Int(nullable: false),
            //            BackrestAssemblyNo = c.String(maxLength: 20),
            //            CushionAssemblyNo = c.String(maxLength: 20),
            //            SlideNo = c.String(maxLength: 20),
            //            BackrestCoverNo = c.String(maxLength: 20),
            //            CushionCoverNo = c.String(maxLength: 20),
            //            BackrestFoamNo = c.String(maxLength: 20),
            //            CushionFoamNo = c.String(maxLength: 20),
            //            BackFrameNo = c.String(maxLength: 20),
            //            SABNo = c.String(maxLength: 20),
            //            HeadrestNo = c.String(maxLength: 20),
            //            CenterHeadrestNo = c.String(maxLength: 20),
            //            ArmRestNo = c.String(maxLength: 20),
            //            BuckleNo = c.String(maxLength: 20),
            //            BackplaneNo = c.String(maxLength: 20),
            //            AdjusterNo = c.String(maxLength: 20),
            //            AdjusterPlateNo = c.String(maxLength: 20),
            //            CushioSsupportNo = c.String(maxLength: 20),
            //            IsDeleted = c.Boolean(nullable: false),
            //            DeleterUserId = c.Long(),
            //            DeletionTime = c.DateTime(),
            //            LastModificationTime = c.DateTime(),
            //            LastModifierUserId = c.Long(),
            //            CreationTime = c.DateTime(nullable: false),
            //            CreatorUserId = c.Long(),
            //        },
            //    annotations: new Dictionary<string, object>
            //    {
            //        { "DynamicFilter_Online_SoftDelete", "EntityFramework.DynamicFilters.DynamicFilterDefinition" },
            //    })
            //    .PrimaryKey(t => t.Id)
            //    .ForeignKey("dbo.T_BasicLine", t => t.LineId, cascadeDelete: true)
            //    .Index(t => t.LineId);
            
        }
        
        public override void Down()
        {
            //DropForeignKey("dbo.T_Online", "LineId", "dbo.T_BasicLine");
            //DropIndex("dbo.T_Online", new[] { "LineId" });
            //DropTable("dbo.T_Online",
            //    removedAnnotations: new Dictionary<string, object>
            //    {
            //        { "DynamicFilter_Online_SoftDelete", "EntityFramework.DynamicFilters.DynamicFilterDefinition" },
            //    });
        }
    }
}
